(function (win) {
    win.constant = {};
    constant.x = 0;
    constant.y = 0;
    constant.width = window.innerWidth;
    constant.height =  window.innerHeight;
    constant.centX =  window.innerWidth / 2;
    constant.centY = window.innerHeight / 2;

    constant.tu = {

    }


    constant.isLandscape = function () {
        return this.width > this.height;
    };
    constant.reload = function () {
        if(screen.orientation.angle==180||screen.orientation.angle==0){
            //alert("请旋转手机，横屏自动开始游戏！");
            constant.x = window.innerWidth;
            constant.y = 0;
            constant.width = window.innerHeight;
            constant.height = window.innerWidth;
            constant.centX = window.innerWidth / 2;
            constant.centY = window.innerHeight / 2;
        }
      /*  if(screen.orientation.angle==90||screen.orientation.angle==-90){
            //alert("横屏状态！")

        }*/



    }
})(window)